<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8"/>
    <title>{$title}</title>
    <link type="text/css" rel="stylesheet" href="{$url_front}/statics/css/monkey.css"/>
    <!--{$url_front}-->
    <link type="text/css" rel="stylesheet" href="{$url_front}/statics/css/frame.css"/>
    <link type="text/css" rel="stylesheet" href="{$url_front}/statics/css/powerFloat.css"/>
    <style type="text/css">html, body {
        width: 100%;
        height: 100%;
    }</style>
    <script type="text/javascript" src="{$url_front}/statics/js/jquery.min.js"></script>
    <script type="text/javascript" src="{$url_front}/statics/js/jquery.layout.min.js"></script>
    <script type="text/javascript">
        $(function () {

            //loayout
            myLayout = $("body").layout({
                north__size: 50,
                west__size: 180,
                west__minSize: 50,
                spacing_open: 0,
                spacing_closed: 0,
                east__initClosed: true,
                north__spacing_open: 0,
                south__spacing_open: 0,
                togglerLength_open: 0,
                togglerLength_closed: 0
            });

            //side_nav
            $('dl.nav_wrap dd:not(.current)').hover(function () {
                $(this).toggleClass("current");
            });
            $('.frame_sidebar dl.nav_wrap:not(:first) dd').hide();
            $('.frame_sidebar dl.nav_wrap:first dt').addClass("current");
            $('.frame_sidebar dl.nav_wrap:first').addClass("nav_bottomline");
            $('dl.nav_wrap dt').click(function () {
                $(this).addClass("current").nextAll("dd").show().parent().siblings().children("dd").hide().prev("dt").removeClass("current");
            });
            $('#nav_wrap').find('a').click(function () {
                crumbs_click(this)
            });
            $('#shortcut').find('a').click(function () {
                if ($(this).attr('target') == 'main') {
                    $('#frame_crumbs').html($(this).html());
                }
            });

        });
        function crumbs_click(e) {
            var nav = $(e);
            if (nav.attr('nav_parent') == nav.attr('nav_id')) {
                $('#frame_crumbs').html($('#' + nav.attr('nav_parent')).html());
            }
            else {
                $('#frame_crumbs').html($('#' + nav.attr('nav_parent')).html() + ' >> ' + $('#' + nav.attr('nav_id')).html())
                        .find('a').click(function () {
                            crumbs_click(this)
                        });
            }
        }
    </script>

    <script type="text/javascript" src="{$url_front}/statics/js/monkey.js"></script>

</head>

<body>
<!--frame_header-->
<div id="shortcut" class="ui-layout-north frame_header">

    <!--logo-->
    <div class="frame_logo">
        <div class="frame_switch iconfont" onclick="myLayout.toggle('west')" title="切换侧栏">&#xf0c9;</div>
    </div>
    <!--/logo-->

    <!--frame_nav-->
    <div class="frame_nav">
        <a href="{$url_index}" target="_blank"><span class="iconfont">&#xf0ac;</span> 前台首页</a>
        <a href="{$url_cache_clear}" target="main"><span class="iconfont">&#xf021;</span> 清除缓存</a>
        <a href="{$url_about}" target="main" style="width: 150px;"><span class="iconfont">&#xf05a;</span> 关于Macaca</a>
    </div>
    <!--/frame_nav-->

    <!--frame_toolbar-->
    <div class="frame_toolbar">
        <a href="{$url_logout}" class="tool_logout f_right" title="注销">
            <span class="iconfont">&#xf011;</span>
        </a>
        <span class="nav_line"> </span>
        <!--<a href="#" class="tool_userinfo f_right"><span class="iconfont">&#xf007;</span> Admin</a>-->
        <a href="{$url_user_edit_me}" class="tool_userinfo f_right" target="main">
            <span class="iconfont">&#xf007;</span> {{user_name}}
        </a>
        <!--<span class="nav_line"> </span>-->
        <!--<a href="#" class="tool_clear f_right" title="清理缓存"><span class="iconfont">&#xf021;</span></a>-->
        <!--<a href="#" class="tool_view f_right" title="查看首页"><span class="iconfont">&#xf0ac;</span></a>-->
    </div>
    <!--/frame_toolbar-->

</div>
<!--/frame_header-->

<!--frame_sidebar-->
<div id="nav_wrap" class="ui-layout-west frame_sidebar scroll_pane">
    <!--as/$nav $group-->
    <dl class="nav_wrap">
        <!--as/$group $item-->
        <!--if/$item.parent == $item.nid-->
        <dt id="nav_{$item.nid}">
            <span class="iconfont">{$item.icon}</span>
            <a href="{$item.url}" target="main" nav_id="nav_{$item.nid}"
               nav_parent="nav_{$item.parent}">{$item.title}</a>
        </dt>
        <!--else/-->
        <dd id="nav_{$item.nid}">
            <a href="{$item.url}" target="main" nav_id="nav_{$item.nid}"
               nav_parent="nav_{$item.parent}">{$item.title}</a>
        </dd>
        <!--/-->
        <!--/-->
    </dl>
    <!--/-->
</div>
<!--/frame_sidebar-->

<!--frame_container-->
<div class="ui-layout-center frame_container">

    <!--frame_crumbs-->
    <div id="frame_crumbs" class="frame_crumbs" style="padding-left: 5px;">
        <span class="iconfont">&#xf015;</span> <a href="#">系统管理</a>
    </div>
    <!--/frame_crumbs-->

    <!--frame_main-->
    <div class="frame_main">
        <iframe frameborder="0" id="main" name="main" src="{$url_main}"></iframe>
    </div>
    <!--/frame_main-->

</div>
<!--/frame_container-->

</body>
</html>